<h1>手术房间列表</h1>

<table>
  <tr>
    <th>手术房间编码</th>
    <th>手术房间名称</th>
    <th>归属室</th>
  </tr>

<% @surger_rooms.each do |surger_room| %>
  <tr>
    <td><%=h surger_room.surger_room_code %></td>
    <td><%=h surger_room.surger_room_name %></td>
    <td><%= SurgerAddress.find_by_id(surger_room.surger_address_id).surger_address_name %></td>
    <td><%= link_to '显示', surger_room %></td>
    <td><%= link_to '编辑', edit_surger_room_path(surger_room) %></td>
    <td><%= link_to '删除', surger_room, :confirm => '你确定删除该房间?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to '新增手术房间', new_surger_room_path %>
